package com.woniuxy.enjoylife.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.woniuxy.enjoylife.entity.Suggest;
import com.woniuxy.enjoylife.entity.dto.SuggestDto;
import com.woniuxy.enjoylife.utils.PageResult;

import java.util.List;

public interface SuggestService extends IService<Suggest> {
    //全查询投诉，包括用户，小区信息（分页）
    public PageResult<List<SuggestDto>> findAll(int reuid,int current,int size);
    //根据uid进行回复，并添加回复人id
    public boolean reply(int id,String reply);
    //根据内容模糊查询并分页
    public PageResult<List<SuggestDto>> findLike(int reuid,String content,int current,int size);
    //根据投诉id查询uid,cid,再根据uid,cid查询用户，小区信息
    public SuggestDto findSuggestDtoById(int id);
    //根据投诉id删除（将status改为1）
    public boolean del(int id);

    //**********************用户角度***********************

    //用户查询自己相关的投书
    public PageResult<List<SuggestDto>> findUserSuggest(int reuid,int current,int size);
    //用户投诉
    public boolean insertSuggest(int uid,int cid,String content);

}
